#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int main()
{	
	char **m_str;

    int n = 0;

    printf("please input a number of memory:\n");
    scanf("%d", &n);

	m_str = malloc(n);

	for (int i = 0; i < n; i++) {
		m_str[i] = malloc(1);
		*m_str[i] = i%10 + 48;
	}
	
	for (int i = 0; i < n; i++) {
		printf("%c\n", *m_str[i]);
	}	
	return 0;
}
